package com.bmps.springcloud.insuredmicroservice.model.trail.response;

import org.apache.commons.lang3.builder.EqualsBuilder;
import org.apache.commons.lang3.builder.HashCodeBuilder;

import java.io.Serializable;

/**
 * @Author :  zlc
 * @Date : 2019/9/10 11:39
 **/
public class TrailResponseDataModel implements Serializable {
   
    private TrailResponseHeaderModel header;

    private TrailResponseModel response;

    public TrailResponseHeaderModel getHeader() {
        return header;
    }

    public void setHeader(TrailResponseHeaderModel header) {
        this.header = header;
    }

    public TrailResponseModel getResponse() {
        return response;
    }

    public void setResponse(TrailResponseModel response) {
        this.response = response;
    }

    @Override
    public boolean equals(Object o) {
        if (this == o) {return true;}

        if (o == null || getClass() != o.getClass()) {return false;}

        TrailResponseDataModel that = (TrailResponseDataModel) o;

        return new EqualsBuilder()
                .append(header, that.header)
                .append(response, that.response)
                .isEquals();
    }

    @Override
    public int hashCode() {
        return new HashCodeBuilder(17, 37)
                .append(header)
                .append(response)
                .toHashCode();
    }

    @Override
    public String toString() {
        return "TrailResponseDataModel{" +
                "header=" + header +
                ", response=" + response +
                '}';
    }
}
